1. Field of Invention
The present invention relates to a printing control method for a printer and to a printer that receives print data from an external device and has a normal print mode in which a direct print image of the print data is printed, and an inverted print mode in which the print image of this print data is printed rotated 180 degrees.
2. Description of Related Art
When a cooking order is entered in from the dining room of a fast food restaurant or other type of store using the POS terminal or POS register of an order entry system, an order preparation ticket showing the order to be prepared is printed from a printer located in the kitchen. Roll paper printers are typically used in the kitchen, and the printer is often placed vertically instead of horizontally, or even hung on the wall, in order to save shelf space and leave more working space for cooking.
When the roll paper printer is placed horizontally, the order preparation ticket issued from the paper exit of the roll paper printer is output vertically from the bottom to the top so that the cook can easily verify what dishes to prepare by reading the order preparation ticket while working. When the roll paper printer is placed in the vertical orientation, however, the order preparation ticket issued from the paper exit of the roll paper printer is output vertically from top to bottom, resulting in the top and bottom of the printout being inverted and the ticket being difficult to read. As a result, instead of simply printing the print image of the received print data directly in the normal print mode, roll paper printers used in such order entry systems rotate the print image of the print data received from the order entry system 180 degrees for printing in the inverted print mode so that the printout is reversed and the order preparation ticket can be read easily. Japanese Unexamined Patent Appl. Pub. JP-A-2005-349746 teaches a printer that can switch between the normal print mode and inverted print mode according to the orientation in which the printer is placed.
In order to rotate the print image of the print data received from an external device 180 degrees, the data contained in the print data received in chronological order must be rearranged in reverse chronological order. The print image of each character and image must also be rotated 180 degrees. Printers having an inverted print mode as described above must therefore sequentially convert the received print data into an image conversion buffer until a break in the print data is detected to generate inverted image data for printing in the inverted print mode, and then print the inverted image data.
When an unexpectedly large amount of print data is received from the external device, the image conversion buffer may overflow before the printer can complete converting all of the print data up to a print data break. When the buffer capacity is exceeded, the data at the end of the print data cannot be moved to the beginning of the inverted image data in the print buffer, and the printer therefore cannot correctly generate the inverted image data. When this situation occurs with the related art, only the inverted image data written to the image conversion buffer before the buffer was filled is printed, and the print data received after the full buffer state was reached is simply dropped without being printed.
When data is printed in this way, however, the print data received by the printer and the printout printed by the printer may not match. For example, the order entry system may have sent print data containing all of the dishes that were ordered and need preparing and the printer may have correctly received the same print data, but all of the dishes may not be printed on the order preparation ticket printed by the kitchen printer. This obviously creates a problem delivering the products ordered by the customer, and casts doubt on the reliability of the order entry system.